<?php
/**
 * Xử lý sự kiện login 
 */
function login()
{
    loadModel('user');
    $username = $_GET['username'];
    $password = $_GET['password'];
echo modelLogin($username, $password);
}

function register()
{
	loadModel('user');
	$username = $_GET['username'];
    $password = $_GET['password'];
	$emai = $_GET['email'];
	$sex = $_GET['sex'];
	$DoB = $_GET['DoB'];
echo modelRegister($username, $email, $password,$sex, $DoB );
}

function logout()
{
	loadModel('user');
}